# Copyright 2010-2024 Google LLC
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

package(default_visibility = ["//ortools/math_opt:__subpackages__"])

cc_binary(
    name = "basic_example",
    srcs = ["basic_example.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:gscip_solver",
        "@com_google_absl//absl/status",
    ],
)

cc_binary(
    name = "cocktail_hour",
    srcs = ["cocktail_hour.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:map_util",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:gscip_solver",
        "//ortools/util:status_macros",
        "@com_google_absl//absl/container:flat_hash_map",
        "@com_google_absl//absl/container:flat_hash_set",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/log:check",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/status:statusor",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/types:span",
    ],
)

cc_binary(
    name = "linear_programming",
    srcs = ["linear_programming.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:glop_solver",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/time",
    ],
)

cc_binary(
    name = "advanced_linear_programming",
    srcs = ["advanced_linear_programming.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:glop_solver",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/time",
    ],
)

cc_binary(
    name = "integer_programming",
    srcs = ["integer_programming.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:gscip_solver",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/time",
    ],
)

cc_binary(
    name = "cutting_stock",
    srcs = ["cutting_stock.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:cp_sat_solver",
        "//ortools/math_opt/solvers:glop_solver",
        "@com_google_absl//absl/log:check",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/status:statusor",
        "@com_google_absl//absl/strings",
    ],
)

cc_binary(
    name = "facility_lp_benders",
    srcs = ["facility_lp_benders.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:glop_solver",
        "//ortools/math_opt/solvers:glpk_solver",
        "//ortools/math_opt/solvers:gurobi_solver",
        "//ortools/math_opt/solvers:pdlp_solver",
        "//ortools/util:status_macros",
        "@com_google_absl//absl/container:flat_hash_map",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/memory",
        "@com_google_absl//absl/random",
        "@com_google_absl//absl/random:distributions",
        "@com_google_absl//absl/random:seed_sequences",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/status:statusor",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/strings:str_format",
        "@com_google_absl//absl/time",
        "@com_google_absl//absl/types:span",
    ],
)

cc_binary(
    name = "lagrangian_relaxation",
    srcs = ["lagrangian_relaxation.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:container_logging",
        "//ortools/base:mathutil",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:glop_solver",
        "//ortools/math_opt/solvers:gscip_solver",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/log:check",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/status:statusor",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/strings:str_format",
    ],
)

cc_binary(
    name = "linear_regression",
    srcs = ["linear_regression.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:gurobi_solver",
        "//ortools/math_opt/solvers:pdlp_solver",
        "@com_google_absl//absl/algorithm:container",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/log:check",
        "@com_google_absl//absl/random",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/status:statusor",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/types:span",
    ],
)

cc_binary(
    name = "mathopt_info",
    srcs = ["mathopt_info.cc"],
    deps = [
        "//ortools/base",
        "//ortools/math_opt/core:solver_interface",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:cp_sat_solver",
        "//ortools/math_opt/solvers:glop_solver",
        "//ortools/math_opt/solvers:glpk_solver",
        "//ortools/math_opt/solvers:gscip_solver",
        "//ortools/math_opt/solvers:gurobi_solver",
        "//ortools/math_opt/solvers:pdlp_solver",
    ],
)

cc_binary(
    name = "tsp",
    srcs = ["tsp.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:gscip_solver",
        "//ortools/math_opt/solvers:gurobi_solver",
        "@com_google_absl//absl/container:flat_hash_set",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/log:check",
        "@com_google_absl//absl/random",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/status:statusor",
        "@com_google_absl//absl/strings",
        "@com_google_absl//absl/types:span",
    ],
)

cc_binary(
    name = "graph_coloring",
    srcs = ["graph_coloring.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:cp_sat_solver",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/status:statusor",
        "@com_google_absl//absl/strings",
    ],
)

cc_binary(
    name = "time_indexed_scheduling",
    srcs = ["time_indexed_scheduling.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "//ortools/math_opt/solvers:cp_sat_solver",
        "//ortools/math_opt/solvers:gscip_solver",
        "//ortools/math_opt/solvers:gurobi_solver",
        "@com_google_absl//absl/algorithm:container",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/log",
        "@com_google_absl//absl/random",
        "@com_google_absl//absl/status",
        "@com_google_absl//absl/status:statusor",
        "@com_google_absl//absl/types:span",
    ],
)

cc_binary(
    name = "area_socp",
    srcs = ["area_socp.cc"],
    deps = [
        "//ortools/base",
        "//ortools/base:logging",
        "//ortools/base:status_macros",
        "//ortools/math_opt/cpp:math_opt",
        "@com_google_absl//absl/flags:flag",
        "@com_google_absl//absl/status",
    ],
)
